//
//  ImageWithLabelView.m
//  ShangChengMoBan
//
//  Created by 张铁军 on 16/8/29.
//  Copyright © 2016年 ping. All rights reserved.
//

#import "ImageWithLabelView.h"

@implementation ImageWithLabelView
-(instancetype)initWithFrame:(CGRect)frame{
    self = [super initWithFrame:frame];
    if (self) {
        [self initView];
    }
    
    return self;
}

-(void)initView{
    self.backgroundColor = [UIColor whiteColor];
    _imageView = [[UIImageView alloc]initWithFrame:CGRectMake(10, 5, 25 , 25)];
    [self addSubview:_imageView];
    
    _nameLabel = [[UILabel alloc]initWithFrame:CGRectMake(_imageView.right, _imageView.top, self.width - 45, _imageView.height)];
    _nameLabel.textColor = MaintextColor;
    _nameLabel.font = [UIFont systemFontOfSize:PuTongFont];
    [self addSubview:_nameLabel];
    [self addSubview:[UILabel drawXiaHuaXianLabel:self.height - 0.5]];
}
/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/

@end
